﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using PSE.Framework.Process;
using PSE.ProcessManager.Entity;

namespace PSE.ProcessManager.Common.Process
{
    public class InteligenceManagerInstanceProcess : HierarchicalProcess<IProcessService>
    {
        private string _productKey = null;
        public string ProductKey
        {
            get { return _productKey; }
            set { _productKey = value; }
        }

        private InstanceEntity _instance = null;
        public InstanceEntity Instance
        {
            get { return _instance; }
            set { _instance = value; }
        }

        protected override Uri GetServiceAddress()
        {
            return new Uri(string.Format("net.pipe://localhost/InteligenceManagerInstance/{0}", this.Name));
        }

        protected override TimeSpan GetStartChildTimeout()
        {
            return new TimeSpan(0, 2, 0);
        }
    }
}
